# -*- coding: utf-8 -*-
# Create time: 2020-03-10 13:24
# Author:Rongzhikai
import os
import time

# 项目根目录
PROJECT_PATH = os.path.dirname(os.path.dirname(os.path.abspath(__file__)))

# 系统名称：读取配置文件，要跑的哪个系统，对应系统的文件夹作登录，给session
PROJECTS = []

# 测试数据目录
TESTDATA_PATH = os.path.join(PROJECT_PATH, 'data')
DATA_FILE = os.path.join(TESTDATA_PATH, 'testcase.xlsx')
SHEETNAME = 'Sheet1'
JSON_FILE = os.path.join(TESTDATA_PATH, 'datas.json')


# 测试用例执行目录
TESTCASE_PATH = os.path.join(PROJECT_PATH, 'testcases')

# 日志文件目录
LOG_PATH = os.path.join(PROJECT_PATH, 'logs')
now = time.strftime('%Y-%m-%d-%H_%M_%S')
LOG_FILE = os.path.join(LOG_PATH, r'log%s.log' % now)

# 测试报告文件目录
REPORT_PATH = os.path.join(PROJECT_PATH, "report")

# 发邮件使用
smtp_server = 'smtp.qq.com'
# mail_user = 'davidling6@163.com'
mail_user = 'jerrykais@foxmail.com'
# password = 'ling1218'
password = 'zcraiuavhorxbijf1'
# 收件人
receivers = ['davidling6@163.com', '609985991@qq.com']
nowtime = time.strftime('%Y%m%d %H:%M:%S')  # 生成当前时间
# 邮件主题
subject = u'接口测试报告-' + nowtime

# 系统地址
PROJECT_IP = '192.168.1.20'
# 参数替换
PATTERN = r'\*<(.*?)>'
